package com.example.takeaway.mapper;

import java.util.List;

import com.example.takeaway.entity.Comments;
import org.apache.ibatis.annotations.Mapper;

/**
 * commentMapper接口
 * 
 * @author ruoyi
 * @date 2025-06-02
 */
@Mapper
public interface CommentsMapper 
{
    /**
     * 查询comment
     * 
     * @param commentsid comment主键
     * @return comment
     */
    public Comments selectCommentsByCommentsid(Long commentsid);

    /**
     * 查询comment列表
     * 
     * @param comments comment
     * @return comment集合
     */
    public List<Comments> selectCommentsList(Comments comments);

    /**
     * 新增comment
     * 
     * @param comments comment
     * @return 结果
     */
    public int insertComments(Comments comments);

    /**
     * 修改comment
     * 
     * @param comments comment
     * @return 结果
     */
    public int updateComments(Comments comments);

    /**
     * 删除comment
     * 
     * @param commentsid comment主键
     * @return 结果
     */
    public int deleteCommentsByCommentsid(Long commentsid);

    /**
     * 批量删除comment
     * 
     * @param commentsids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteCommentsByCommentsids(Long[] commentsids);
}
